{% extends "promos/base.html" %}
{% load i18n %}

{% block head_title %}Preview Promo Billboard{% endblock %}


{% block main_content %}
<h1>Preview Promo Billboard -- {{ billboard }}</h1>
<div class="edit-promo-tabs">
    <div class="tab-links">
        <a href="{% url promos_promo_edit promo_id=promo.id %}" rel="promo-info">Pitch</a>
        <a href="#" rel="promo-info" title="Geotag">Geotag</a>
        <a href="{% url promos_promo_image_list promo_id=promo.id %}">Images</a>
        <a href="{% url promos_promo_link_list promo_id=promo.id %}">Related Links</a>
        <a href="{% url promos_promo_date_list promo_id=promo.id %}">Suggested Dates</a>
        <a href="{% url promos_promo_billboard_list promo_id=promo.id %}" class="active">Billboards</a>
        <a href="{% url promos_promo_detail promo_id=promo.id %}">Detail</a>
        <br class="clearboth" />
    </div>
    <div class="tab-contents">

{% comment %}
<p>
Billboard preview has been temporarily disabled. Look for this to be restored shortly.
</p>
{% endcomment %}


<div id="billboards" style="width:700px;height:360px;">
    {% ifequal billboard.billboard_type '0' %}
        <div style="background: #5c8eb2 url({{ billboard.image.image.url }});width:700px; height:360px;z-index:0; no-repeat;cursor:pointer;cursor:hand;" OnClick="window.location='{% firstof billboard.link.url billboard.promo.permalink %}'">
            {% autoescape off %}<h1><a href="{% firstof billboard.link.url billboard.promo.permalink %}" style="text-decoration:none;position:relative; left:{{ billboard.headline_position_horizontal }}px; top:{{ billboard.headline_position_vertical }}px;z-index:1;color:{{ billboard.headline_color }};">{{ billboard.headline }}</a></h1>{% endautoescape %}
            {% autoescape off %}
            <p style="position:relative; left:{{billboard.supporting_text_position_horizontal}}px; top:{{billboard.supporting_text_position_vertical}}px;z-index:1;color:{{billboard.supporting_text_color}};width:{{billboard.supporting_text_width}}px;text-align:{{billboard.supporting_text_alignment}};"><strong>{{ billboard.supporting_text}}</strong></p>
            {% endautoescape %}
        </div>
        {% else %}
            {% ifequal billboard.billboard_type '1' %}
                <div style="background: #5c8eb2 url({{ billboard.image.image.url }});width:700px; height:360px;z-index:0; no-repeat;cursor:pointer;cursor:hand;" OnClick="window.location='{% firstof billboard.link.url billboard.promo.permalink %}'">
                </div>
            {% else %}
                {% ifequal billboard.billboard_type '2' %}
                    <div style="background: #5c8eb2 url({{ billboard.image.image.url }});width:700px; height:360px;z-index:0; no-repeat;cursor:pointer;cursor:hand;" OnClick="window.location='{% firstof billboard.link.url billboard.promo.permalink %}'">
                {% autoescape off %}
                    <div>{{ billboard.supporting_text}}</div>
                {% endautoescape %}
                    </div>
            {% endifequal %}
        {% endifequal %}
    {% endifequal %}
</div>



{% endblock %}

{% block subnav %}
<h2>Links</h2>
  <ul class="action-links">
    <li><a href="{% url promos_promo_list %}">Promo List</a></li>
    <li><a href='{% url promos_promo_billboard_calendar_now promo_id=promo.id %}'>Calendar</a></li>
 </ul>
{% endblock %}

